const obj = {
  aaa: 'a',
  aaaChildren: {
    bd: 'sd',
    csd: 'bbb'
  },
  bbb: 'c',
  ccc: 'ded',
}
let result = [];
function printAllVal(object, arr) {
  let temp = Object.values(object);
  for(let value of temp) {
    if(typeof(value) === 'object') {
      printAllVal(value, arr);
    } else {
      arr.push(value);
    }
  }
  return arr;
}
printAllVal(obj, result);
console.log(result);



